-
-
Notifications
You must be signed in to change notification settings - Fork 593
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix #524 check for type list and improve error msg #534
Conversation
Codecov Report
@@ Coverage Diff @@
## master #534 +/- ##
==========================================
+ Coverage 90.95% 90.97% +0.02%
==========================================
Files 28 28
Lines 2652 2660 +8
==========================================
+ Hits 2412 2420 +8
Misses 240 240
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
tests/test_tablib.py
Outdated
def test_yaml_load(self): | ||
""" test issue 524: invalid format """ | ||
yaml_source = Path(__file__).parent / 'files' / 'issue_524.yaml' | ||
with open(str(yaml_source), mode='rb') as fh: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you should be able to write with yaml_source.open(mode='rb') as fh:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for your contribution!
Noticed that coverage job failed on master. I will fix it with a new PR. |
Frankly, coverage reports are generally so broken I don't even consider them. |
Just in case created this PR https://github.com/jazzband/tablib/pull/535/files Found a small bug when using empty files. Not sure if it is better to raise an exception or return empty list. |
Unit test to reproduce the issue #524 and improve error message